//
//  GIftPackage.swift
//  LiveShow
//
//  Created by dai zhong on 2017/5/10.
//  Copyright © 2017年 company.cn. All rights reserved.
//

import Foundation

class GIftPackage: BaseModel {
    
    var list :[GiftModel] = []
    var p :NSInteger = 0;
    var t :NSInteger = 0;
    var tp :NSInteger = 0;
    
    override func setValue(_ value: Any?, forKey key: String) {
        
        if key == "list" {
        
            guard let listArray = value as? [[String :Any]] else { return }
            for dict in listArray{
                
                list.append(GiftModel(dict: dict))
            }
        }else{
            super.setValue(value, forUndefinedKey: key)
        }
    }
}
